This invention relates to a technique of correcting digital image data obtained by a scanner or a digital camera such that, particularly, a main subject has a proper density.
There is known an apparatus provided with a function of enabling a density correction to adjust the density of an outputted image, particularly main subject, to a proper level in the case of outputting a digital image obtained by a scanner or a digital camera to a monitor, a printer or the like.
A known method for this density correction is such that an average value of the density of the entire image data is obtained for each of the respective color components of R (red), G (green), B (blue) of the digital image data, and histograms of the respective color components R, G, B are corrected such that the density average values coincide with density reference values set beforehand.
In the case that the density correction is applied by the above method to an image having a skewed density distribution in the entire image such as an image obtained by photographing a human figure as a main subject against a bright background without using a flash device or an image obtained by photographing a human figure as a main subject against a dark background using a flash device, there has been a problem that the density of the human figure as the main subject cannot be properly corrected by being influenced by the background.
For instance, image data obtained by photographing a human figure as a main subject against a dark background using a flash device has a large density average value. Thus, if the density correction is applied to this image data by the above method, such a density correction as to reduce the entire density is applied, which makes the density of the human figure as the main subject excessively low. As a result, an output image having a proper density cannot be obtained.